var express = require('express');
var router = express.Router();
const connection = require('../database/mysql')
const path = require('path')
const sql = require('../routehandles/mysqlhandle');
const { request } = require('http');


router.post('/processjieshou',async (req,res) => {
    const params = req.body;
    var b = await sql.sPushTableBytasknumAndusername(params.username,params.tasknum);//保证这个username是接受任务的人
    console.log("输出username")
    console.log(params.username)
    console.log("输出tasknum")
    console.log(params.tasknum)
    console.log("数据库返回值看这儿")
        console.log(b)
        console.log(typeof(b))
        return res.json({b,result:'true'})
})

module.exports = router